<script>
import {openTime} from 'request/time.js'//获取营业时间
import {time_range} from 'ulits/tool.js'
	export default {
		onLaunch: function() {
			openTime().then(res=>{
				var time=time_range(res[1].data.data.start_time,res[1].data.data.end_time)
				if(!time){
					uni.showModal({
					    title: '提示',
					    content: '当前时间不可下单,或已打烊',
					    success: function (res) {
					        
					    }
					});
				}
				
			})
		},
		onShow: function() {
			//console.log('App Show')
		},
		onHide: function() {
			//console.log('App Hide')
		}
	}
</script>

<style lang="scss">
@import "uview-ui/index.scss";
</style>
